﻿using System;
using System.Collections.Generic;
using System.Linq;
using Dapper.Contrib.Extensions;

namespace WoChu.DeliverCenter.Entity
{
    /// <summary>
    /// 
    /// </summary>
    [Table("Deli_Order")]
    public partial class DeliOrder
    {
        public DeliOrder()
        {
            DeliOrderDetailList = new List<DeliOrderDetail>();
        }

        #region 属性
        /// <summary>
        /// 订单编号
        /// </summary>
        public string OrderNo { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string DeliveryNo { get; set; }

        /// <summary>
        /// 订单状态
        /// </summary>
        public byte OrderStatus { get; set; }

        /// <summary>
        /// 配送单状态
        /// </summary>
        public byte DeliveryStatus { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public DateTime OrderAddTime { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string PayName { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string UserID { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string UserName { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string Consignee { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string ConsigneeMobile { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string Province { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string City { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string District { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string Address { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string Batch { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string DeliveryPeriod { get; set; }

        /// <summary>
        /// 配送时段
        /// </summary>
        public DateTime ExpectedDate { get; set; }

        /// <summary>
        /// 自提点地址(第三方配送)
        /// </summary>
        public string PointName { get; set; }

        /// <summary>
        /// 配送站点ID
        /// </summary>
        public int SiteID { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public int TruckID { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public int DriverID { get; set; }

        /// <summary>
        /// 批次号
        /// </summary>
        public string BatchNo { get; set; }

        /// <summary>
        /// 批次子号
        /// </summary>
        public string BatchSubNo { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string BatchNoHis { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public byte IsDel { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string DeliveryBatch { get; set; }

        /// <summary>
        /// 票号
        /// </summary>
        public string TicketNo { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public int StaffID { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string StaffName { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string Latitude { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string Longitude { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string DeliveryBatchNo { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string DeliveryBatchSubNo { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string DeliveryBatchNoHis { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public byte IsProduct { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal ProductAmount { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal ShippingFee { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal InsureFee { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal PayFee { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal PackFee { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal CardFee { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal MoneyPaid { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal Surplus { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal Integral { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal IntegralMoney { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal Bonus { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal OrderAmount { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string ShippingName { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public byte OrderAPPVersion { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal Discount { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public DateTime UpdateDate { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public DateTime DeliveryBeginDate { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public DateTime DeliveryEndDate { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string BatchDeliveryPeriodHis { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public DateTime BatchDeliveryBeginDate { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public DateTime BatchDeliveryEndDate { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public byte ShippingStatus { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public DateTime PayTime { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public int PayStatus { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string SerialNumber { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public byte roadNo { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public int TicketSort { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public byte orderType { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string AddressHis { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string ProvinceHis { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string CityHis { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string DistrictHis { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal NeedToPay { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal VoucherCodeMoney { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public decimal VoucherMoney { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string Remark { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string CustomServiceRemark { get; set; }
        #endregion

    }

    /// <summary>
    ///  扩展属性
    /// </summary>
    public partial class DeliOrder
    {
        public List<string> CheckOrderNos { get; set; }

        /// <summary>
        /// 订单明细列表
        /// </summary>
        public List<DeliOrderDetail> DeliOrderDetailList { get; set; }
    }
}

